package com.lk.common.kafka;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("/kafka")
public class KafkaTestController {
	
	@Autowired
	KafkaProducerServer kafkaProducerServer;
	
	@RequestMapping("/test")
	@ResponseBody
	public String testKafka() {
		kafkaProducerServer.sndMesForTemplate("test", "aa", "0", 1, "IM");
		return "测试";
	}
}
